import regExp from './RegExp.js';

export default {
  trimSpace(str) {
    return str.replace(/\s+/, '')
  },

  checkLength(str, min, max) {
    let sStr = String(str);

    return sStr.length && (sStr.length >= min || sStr <= max)
  },

  checkEmail(str) {
    return regExp.email.test(str)
  }
}